#pragma once

#include <QDialog>
#include <QPushButton>
#include <QLineEdit>
#include <QLabel>
#include <QComboBox>
#include "publicgui_global.h"

namespace VrDataCore
{
	class DeviceActor;
}

namespace PublicGui
{
	class PUBLICGUI_EXPORT EditActorDialog : public QDialog
	{
		Q_OBJECT
	public:
		EditActorDialog(QWidget* parent=0,Qt::WindowFlags f=0);
		~EditActorDialog();
		void setEditActor(VrDataCore::DeviceActor* actor);
		QString getType();
		QString getEditNameText();
		void setEditNameText(const QString& text);
		QString getEditTypeText();
		void setEditTypeText(const QString& text);
		QString getSubTypeText();
		void setSubTypeText(const QString& text);
	private:
		QLineEdit*									_lineEditName;
		QComboBox*									_actorTypeCom;
		QLineEdit*									_lineEditType;
		QLineEdit*									_lineEditSubType;
		QLineEdit*									_lineEditSubTypeLow;
		QPushButton*								_okButton;
		QPushButton*								_cancelButton;
		VrDataCore::DeviceActor*					_editActor;
		QMap<QString,QString>						_nameToType;
	private slots:
		void slotEnter();
	};
}